home *** CD-ROM | disk | FTP | other *** search
/ Tech Arsenal 1 / Tech Arsenal (Arsenal Computer).ISO / tek-02 / prodpack.zip / DB4PPSRC.EXE / SETVAR.PRG < prev   
Text File  |  1993-05-04  |  1KB  |  34 lines

  1. *' $Header: $
  2. FUNCTION SetVar
  3. PARAMETERS pc_VarName, p__value
  4. *----------------------------------------------------------------------------
  5. * NAME
  6. *   SetVar() - Sets the value of a variable
  7. *
  8. * DESCRIPTION
  9. *   SetVar() will set the value of a named variable.  SetVar()'s 
  10. *   intention is for use in the debugger.  For example, if an expression
  11. *   fails due to an EOF condition or a bad macro expansion, SetVar()
  12. *   will allow you to set the value and proceed with the program.
  13. *
  14. * PARAMETERS
  15. *   pc_VarName = Name of the variable to set.  If not already defined,
  16. *                the variable will be defined as a PUBLIC.
  17. *   p__value   = The value to store in the variable.
  18. *
  19. *----------------------------------------------------------------------------
  20.   cVarName = pc_VarName
  21.   IF TYPE( cVarName ) = "U"
  22.     PUBLIC &cVarName
  23.   ENDIF
  24.   STORE p__value TO &cVarName
  25. RETURN( p__value )
  26. *-- EOF: SetVar( pc_VarName, p__value )
  27. *'----------------------------------------------------------------------------
  28. *' $Log: $
  29. *'----------------------------------------------------------------------------
  30.  
  31.  
  32.  
  33.  
  34.